package org.naxx.security.datatype;

/**
 * Able to translate from string representation of certain
 * type to its Java object representation.
 */
public interface DataTypeValueResolver {
	
	/**
	 * Converts source string into target data type value. 
	 * Implementation will trim() source string before processing.
	 * 
	 * @param dataType type in which transformation should be performed
	 * @param source string representation of type value
	 * @return object of specified data type
	 */
	public Object resolveValue(DataType dataType, String source);
}
